package com.gz.moreaseManager.modules.mapper;

import com.gz.moreaseManager.modules.entity.Brand;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;
import java.util.Map;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author wike
 * @since 2019-02-25
 */
public interface BrandMapper extends BaseMapper<Brand> {

    /**
     * 根据权限码获取品牌信息
     * @param authCode
     * @return
     */
    List<Brand> findBrandByAuthCode(String authCode);

    /**
     * 根据权限码+年份获取品牌信息
     * @param authCode
     * @return
     */
    List<Brand> findBrandByAuthCodeAndYear(@Param("authCode") String authCode, @Param("year")Integer year );

    /**根据权限码获取所有年份**/
    Map findBrandYearList(String authCode);
}
